package com.xbongbong.paas.pojo.dto;

import com.xbongbong.paas.toolbox.wrap.BaseDTO;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;

/**
 * 新建应用DTO
 * @author kaka
 * @time 2018-7-30 16:01
 */
@Setter
@Getter
@ToString
public class ApplicationUpdateDTO extends BaseDTO {

    private static final long serialVersionUID = 321148966217874448L;

    /**
     * 新建的应用id
     */
    @NotNull(message = "{dto.msg.applicationDel.id.NotNull}")
    private Long id;

    /**
     * 应用名
     */
    @NotNull(message = "{dto.msg.applicationAdd.name.NotBlank}")
    @Length(min = 1, max = 20, message = "{dto.msg.applicationAdd.name.Length}")
    private String name;

    /**
     * 应用名英文版
     */
    @NotNull(message = "{dto.msg.applicationAdd.name.NotBlank}")
    @Length(min = 1, max = 50, message = "{dto.msg.applicationAdd.name.Length}")
    private String nameEn;

    /**
     * 应用图标
     */
    private String icon;

    /**
     * 应用颜色，十六进制RGB
     * 如 #FFB6C1
     */
    @Length(min = 7, max = 7, message = "{dto.msg.applicationAdd.color.Length}")
    private String color;

    private Integer sort;

    private Integer enable;
}
